INDEX = {};
INDEX.lunbo=function(){ 
	var myApp_ = new Framework7();
	var mySwiper = myApp_.swiper('.swiper-container', {
		pagination: '.swiper-pagination'
	});
}
INDEX.__INIT__ = function () {
	INDEX.lunbo();
    INDEX.fill();
    $(".location_name").html(SESSION.get_community_name());
} 
INDEX.fill = function () {
    var url = url_('api/V0/index');
    var data = {
    	community_id: SESSION.get_community_id()
	};
    var success = function (d) {
        if (d.code == 0) {
            // 渲染购物车上标
            user_cart_count();
//          var source = $("#goods_container").html();
//          alert(source)
//          if (!source) {
                var r_data = d.data;
                $.tpl({
                    elem: ".index_goods_container",
                    url: "src/index/index_fill.html",
                    context: r_data
                });
//          } else {
//
//          }
        } else if (d.code == 1031) {
            my_tips_(d.msg, function () {
                go_("choice_community");
            })
        } else {
            my_tips_(d.msg);
        }
    }
    request_(url, data, success)
}
